<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ page isELIgnored="false"%>
<%@ include file="../common/taglibs.jsp"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<!doctype html>
<html lang="zh-CN">
<head>
	<meta charset="UTF-8">
	<meta http-equiv="X-UA-Compatible" content="IE=edge">
	<meta name="renderer" content="webkit">
	<title>云商宝终端激活统计</title>
	<link rel="icon" href="favicon.ico" type="image/x-icon"/>
	<!-- 当前页面样式 -->
	<link rel="stylesheet" href="<s:url value="/css/common.css"/>"/>
	<!-- 当前页面样式 END -->
	<script type="text/javascript" src="<c:url value="/js/jquery-1.3.2.js" />"></script>
	<script type="text/javascript" src="<c:url value="/js/common.js" />"></script>
	<script type="text/javascript" src="<c:url value="/js/My97DatePicker/WdatePicker.js"/>"></script>
	<script type='text/javascript' src='<s:url value="/js/pageAjax.js"/>'></script>
	<script type='text/javascript' src='<s:url value="/dwr/engine.js"/>'></script>
	<script type='text/javascript' src='<s:url value="/dwr/interface/MccQuery.js"/>'></script>
	<script type='text/javascript' src='<s:url value="/js/querySon.js"/>'></script>
	<script type="text/javascript">
	function queryForm(obj){
		$("#"+obj.id).attr("disabled",true);
		$("#queryTermForm").attr("action","<%=basePath%>/termianlActCount/termianlCountForYsbList.ct");
		$("#queryTermForm").submit();		
	}
	
	function exportSubmit(){
		$("#queryTermForm").attr("action","<%=basePath%>/termianlActCount/exportYsbTermActList.ct");
		$("#queryTermForm").submit();
		$(this).attr("disabled","true");
	}
	</script>
</head>
<body>
<s:form id="queryTermForm" action="" method="post" theme="simple">
<table class="tb">
	<tbody>
		<tr class="tb-line">
			<td class="tb-td" colspan="4"><div class="tb-h2">POS收单运营管理平台</div></td>
		</tr>
		<tr class="tb-line">
			<td class="tb-td" colspan="4"><div class="tb-h3">云商宝终端激活统计</div></td>
		</tr>
		<tr class="tb-line">
			<td align="right" class="tb-td">
				<div class="tb-h4">大区：</div>
			</td>
			<td class="tb-td">
				<label class="tb-input-normal">
					<s:textfield  name="searchCondition.areaName" />
				</label>
			</td>
			<td align="right" class="tb-td">
				<div class="tb-h4">入网方式：</div>
			</td>
			<td class="tb-td">
				<label class="tb-input-mini">
					<s:select list="#{'99':'请选择状态','携机入网':'携机入网','定制机':'定制机'}" name="searchCondition.posType" />
				</label>
			</td>
		</tr>
		<tr class="tb-line">
			<td class="tb-td line-submit" align="right" colspan="4">
				<label class="tb-input-submit">
					<input type="button" value="查询" id="queryBtn" onclick="queryForm(this)"/>
				</label>
				<label class="tb-input-submit">
						<input id="szPower" type="button" value="导 出" onclick="return exportSubmit();"/>
				</label>
				<label class="tb-input-submit">
					<input type="reset" value="取消"/>
				</label>
			</td>
		</tr>
		<tr class="tb-line">
			<td class="tb-td line-submit" align="center" colspan="4">
				<font color="red" id="msgInfo"><s:actionmessage/><s:actionerror/>
					<s:if test="#request.COUNT != null">
						统计：当前查询条件共计[<font color="red"><s:property value="#request.COUNT"/></font>]条数据
					</s:if>
				</font>
			</td>
		</tr>
		<s:if test="#request.searchRsList != null && #request.searchRsList.size>0 ">
			<tr class="tb-line">
				<td class="tb-td paging"  align="left" colspan="4"> 
						<page:pageCount max_pages="11" totalPage="${requestScope.totalPage}"
						currentPage="${requestScope.currentPage}"
						action="${rootPath}/termianlActCount/termianlCountForYsbList.ct?currentPage=" />
				</td>
			</tr>
		</s:if>
	</tbody>
</table>
</s:form>
<div class="big-tb">
	<table class="tb" style="width: 100%;">
		<thead>
			<tr class="tb-line">
				<th class="tb-th" colspan="6">云商宝终端激活统计信息列表</th>
			</tr>
			<tr class="tb-line bg-gray">
					<th class="tb-th">大区</th>
					<th class="tb-th">一级代理商名称</th>
					<th class="tb-th">一级代理商账号</th>
					<th class="tb-th">数量</th>
					<th class="tb-th">前一天数量</th>
					<th class="tb-th">入网方式</th>
			</tr>
		</thead>
	<tbody>
		<s:iterator value="#request.searchRsList" status="stat" id="sh">
			<tr class="tb-line" >
					<td class="tb-td"><s:property value="#sh.areaName"/></td>
					<td class="tb-td"><s:property value="#sh.oneagentName"/></td>
					<td class="tb-td"><s:property value="#sh.oneagentNo"/></td>
					<td class="tb-td"><s:property value="#sh.posCount"/></td>
					<td class="tb-td"><s:property value="#sh.yesday"/></td>
					<td class="tb-td"><s:property value="#sh.posType"/></td>
			</tr>
		</s:iterator>
	</tbody>
	</table>
</div>
 <s:if test="#request.msg !=null">
		<script language="javascript">
			alert("${request.msg}");
		</script>
	</s:if>
</body>
</html>